package la.iok.hzsvn.lewin.movie.core.shopmovie.param;

import java.util.Date;
import java.util.Objects;

/**
 * 优惠券使用记录的列表过滤参数
 */
public class CouponUseRecordListParam {
    /**
     * 拼车id
     */
    private Long carpoolId;
    /**
     * 优惠券id
     */
    private Long couponId;
    /**
     * 使用的店铺。
     */
    private Long orgUnitId;
    /**
     * 使用优惠券的用户id
     */
    private Long userId;
    /**
     * 状态。0：创建状态，也是默认状态。10：已确认,使用券经过确认并返现给了用户。0-10之间的状态保留
     */
    private Integer status;
    /**
     * 过滤的开始时间,以使用时间过滤
     */
    private Date start;
    /**
     * 过滤的结束时间,以使用时间过滤
     */
    private Date end;

    public Long getCarpoolId() {
        return carpoolId;
    }

    public void setCarpoolId(Long carpoolId) {
        this.carpoolId = carpoolId;
    }

    public Long getCouponId() {
        return couponId;
    }

    public void setCouponId(Long couponId) {
        this.couponId = couponId;
    }

    public Long getOrgUnitId() {
        return orgUnitId;
    }

    public void setOrgUnitId(Long orgUnitId) {
        this.orgUnitId = orgUnitId;
    }

    public Long getUserId() {
        return userId;
    }

    public void setUserId(Long userId) {
        this.userId = userId;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public Date getStart() {
        return start;
    }

    public void setStart(Date start) {
        this.start = start;
    }

    public Date getEnd() {
        return end;
    }

    public void setEnd(Date end) {
        this.end = end;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (!(o instanceof CouponUseRecordListParam)) return false;
        CouponUseRecordListParam listParam = (CouponUseRecordListParam) o;
        return Objects.equals(carpoolId, listParam.carpoolId) && Objects.equals(couponId, listParam.couponId)
                && Objects.equals(orgUnitId, listParam.orgUnitId) && Objects.equals(userId, listParam.userId)
                && Objects.equals(status, listParam.status) && Objects.equals(start, listParam.start)
                && Objects.equals(end, listParam.end);
    }

    @Override
    public int hashCode() {
        return Objects.hash(carpoolId, couponId, orgUnitId, userId, status, start, end);
    }

    @Override
    public String toString() {
        return "CouponUseRecordListParam{" +
                "carpoolId=" + carpoolId +
                ", couponId=" + couponId +
                ", orgUnitId=" + orgUnitId +
                ", userId=" + userId +
                ", status=" + status +
                ", start=" + start +
                ", end=" + end +
                '}';
    }
}
